package com.server.pinggu.service.impl;

import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import org.apache.commons.lang3.StringUtils;
import com.server.pinggu.mapper.SenSetsotherMapper;
import com.server.pinggu.domain.SenSetsother;
import com.server.pinggu.service.ISenSetsotherService;

import java.util.List;

/**
 * 【请填写功能名称】Service业务层处理
 *
 * @author ltao
 * @date 2022-10-23
 */
@Service
public class SenSetsotherServiceImpl extends ServiceImpl<SenSetsotherMapper, SenSetsother> implements ISenSetsotherService {

    @Override
    public List<SenSetsother> queryList(SenSetsother senSetsother) {
        LambdaQueryWrapper<SenSetsother> lqw = Wrappers.lambdaQuery();
        if (senSetsother.getSid() != null){
            lqw.eq(SenSetsother::getSid ,senSetsother.getSid());
        }
        if (StringUtils.isNotBlank(senSetsother.getContent())){
            lqw.eq(SenSetsother::getContent ,senSetsother.getContent());
        }
        return this.list(lqw);
    }
}